<?
include("common/header.html");
include("../_made/le.cfg.php");
include("common/left.html");
if(!$_SESSION['memberID']){exit("<script>window.location='dlogin.html'</script>");}
include_once('common/autoload.php');
$s2=SoapInit::GetsoapInside();
$id=$_REQUEST["id"];
$dist=new Dist();
$m_info=$dist->getInfo($id);
if($m_info['dtype']==0 || $m_info['dtype']==1){$name="公司名称";$photo="企业LOGO";}
elseif($m_info['dtype']==5 || $m_info['dtype']==6){$name="姓&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;名";$photo="我的头像";}
elseif($m_info['dtype']==7){$name="集团名称";$photo="集团LOGO";}
else{$photo="商家标识";}
//if(!$origin){$origin=array(array());$originisnull=1;}
$s=new richmodule;
$s->Fetch_Module_File("tpl/g_info.tpl");
foreach($m_info as $k=>$v){
	if($k=="com_type"){
		$com_type=explode(",",$v);
		foreach($com_type as $c){
			switch($c){
				case "旅行社":$s->Fetch_String("com_type0","checked");break;
				case "加盟门店":$s->Fetch_String("com_type1","checked");break;
				case "电商/团购网":$s->Fetch_String("com_type2","checked");break;
				case "淘宝/天猫":$s->Fetch_String("com_type3","checked");break;
				case "其他":$s->Fetch_String("com_type4","checked");break;
			}
		}
	}
	else{
		$s->Fetch_String($k,$v);
	}
}
$s->Fetch_String("id",$id);
$s->Fetch_String("name",$name);
//$s->Fetch_Array("origin", $origin,0,$originisnull);
$s->Set_Array_On();
if($_SESSION['memberID']!=1){
	$s->Make_If_Module("zzrz", 0);
}
else{
	if(!$m_info['bsn_les']){$s->Make_If_Module("bsn_les", 0);}
	if(!$m_info['opt_les']){$s->Make_If_Module("opt_les", 0);}
	if(!$m_info['id_card']){$s->Make_If_Module("id_card", 0);}
	$money=simplexml_load_string($s2->PFT_Member_Fund($id,0));
	$s->Fetch_String("money",$money->Rec[0]->UUamoney/100);
}
if($m_info['dtype']==6){$s->Make_If_Module("jt", 0);}
$s->Output_Html();
include("common/footer.html");?>